import request from '@/utils/request'

export function addInfo(data) {
    return request({
      url: '/api/student/info/add',
      method: 'post',
      params: data
    })
  }
  export function deleteInfo(id) {
    return request({
      url: '/api/student/info/delete',
      method: 'post',
      params: id
    })
  }
  export function updateInfo(StudentInfo) {
    return request({
      url: '/api/student/info/update',
      method: 'post',
      params: StudentInfo
    })
  }
  export function searchInfo(query) {
    return request({
      url: '/api/student/info/search',
      method: 'get',
      params: query
    })
  }
  export function getInfo(query) {
    return request({
      url: '/api/student/info/searchById',
      method: 'get',
      params: query
    })
  }

  export function getStay(query) {
    return request({
      url: '/api/student/stay/searchById',
      method: 'get',
      params: query
    })
  }
  export function addStay(StudentStay) {
    return request({
      url: '/api/student/stay/add',
      method: 'post',
      params: StudentStay
    })
  }
  export function deleteStay(StudentStay) {
    return request({
      url: '/api/student/stay/delete',
      method: 'post',
      params: StudentStay
    })
  }
  export function updateStay(StudentStay) {
    return request({
      url: '/api/student/stay/update',
      method: 'post',
      params: StudentStay
    })
  }
  export function searchStay(query) {
    return request({
      url: '/api/student/stay/search',
      method: 'get',
      params: query
    })
  }
  export function addVolunteer(data) {
    return request({
      url: '/api/student/volunteer/add',
      method: 'post',
      params: data
    })
  }
  export function deleteVolunteer(id){
    return request({
      url: '/api/student/volunteer/delete',
      method: 'post',
      params: id
    })
  }
  export function updateVolunteer(StudentVolunteer) {
    return request({
      url: '/api/student/volunteer/update',
      method: 'post',
      params: StudentVolunteer
    })
  }
  export function searchVolunteer(query) {
    return request({
      url: '/api/student/volunteer/search',
      method: 'get',
      params: query
    })
  }
  export function getVolunteer(query) {
    return request({
      url: '/api/student/volunteer/searchById',
      method: 'get',
      params: query
    })
  }
